package io;

import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;

public class Demo2 {
    public static void main(String[] args) throws IOException {
        //读
        FileInputStream fis = new FileInputStream("Day12\\abc\\a.txt");
        //写
        FileOutputStream fos = new FileOutputStream("b.txt");

        int len;
        byte [] arr = new  byte[1024];
        while ((len = fis.read())!=-1){
            fos.write(arr,0,len);
        }
        fis.close();
        fos.close();
    }
}
